Hệ thống quản lý trường học bằng PHP / MySQLi

1 <?php
2 error_reporting(
0);
3 $conn=mysqli_connect(
'localhost','root','','sms2')or die(mysqli_error("Connection error"));
4 ?>
5 <?php
6  session_start();

7 //Check whether the session variable SESS_MEMBER_ID
is present or not
8 if
(!isset($_SESSION['admin_id']) || (trim($_SESSION['admin_id']) == '')) { ?>
9
10 <?php
11 }
12 $session_id=$_SESSION[
'id'];
13 $user_query = mysqli_query($conn,
"select * from admin where admin_id = '$session_id'")or die(mysqli_error());
14 $user_row = mysqli_fetch_array($user_query);
15 $user_username = $user_row[
'username'];
16 ?>


Gõ tìm kiếm nhanh...